in v-for you cannot use this.type to get data()
you should use a custom property to bind your data() in list item

data() {
    return {
        type: 'institution',
    }
},
<tbody>
    <tr v-for="(item) in participantData"
        type="this.type"
        :key="item.name">
        <td class="text-green-700 font-bold">
          <router-link :to=`/profile/${type}/${item.id}`>{{ item.name }}</router-link>
        </td>
        <td class="">{{ (item.totalEfficacy*100).toFixed(0) }} %</td>
        <td>{{ item.participation }}</td>
    </tr>
</tbody>
#Vue







你可能感興趣的文章

架站研究1

架站研究1

【閱讀】真相製造:從聖戰士媽媽、極權政府、網軍教練、境外勢力、打假部隊、內容農場主人到政府小編

【閱讀】真相製造:從聖戰士媽媽、極權政府、網軍教練、境外勢力、打假部隊、內容農場主人到政府小編

給自己的~儲存方式有3種:cookie、local storage、session storage

給自己的~儲存方式有3種:cookie、local storage、session storage






留言討論